Adding member variables and functions
to the CEmbeddable_Designer class
To return to the previous part of this procedure, go to Adding member variables for the Embeddable Designer dialog controls.
Add the following member variables, and member functions to the CEmbeddable_Designer class. The code for the functions will be added in Step 3: Writing the code (Microsoft Visual C++).
- Create the following member variables.
- Application pointer for the Craxddrt Application Object:
- Variable Type: IApplicationPtr
- Variable Name: m_Application
- Report pointer for the Craxddrt Report Object:
- Variable Type: IReportPtr
- Variable Name: m_Report
- Create the following member function:
- Function to create or open a report and initialize the controls on the Embeddable Designer form.
- Function Type: void
- Function Declaration: InitReport(BOOL bNew)
- Add a member function for the BN_CLICKED message of each of the following buttons:
- New Report: (Click to create a new report)
- Member function name: OnNewReport
- Open Report: (Click to open an existing report)
- Member function name: OnOpenReport
- Save Report: (Click to save the current report)
- Member function name: OnSaveReport
- Preview: (Click to Preview the current report)
- Member function name: OnPreview
- Design: (Click to edit the current report)
- Member function name: OnShowDesigner
To continue with this procedure, go to Step 3: Writing the code (Microsoft Visual C++).